<html>
	<head>
		<meta charset="utf-8"></meta>
		<title>BHolder</title>
		<link href="./style.css" rel="stylesheet" type="text/css"/>
	</head>
	<body>
		<div class="class" name="BHolder">
			<h1>BHolder</h1>
			<p id="resume">BHolder是东西（BThing）的引用计算器。<a href="#desc">详细</a></p>
			<h2>public</h2>
			<table id="public">
				<tr><td align="right">inline </td><td><a href="#BHolder()">BHolder</a>();</td></tr>
				<tr><td align="right">inline </td><td><a href="#BHolder(T*)">BHolder</a>(T* thing);</td></tr>
				<tr><td align="right">inline </td><td><a href="#BHolder(const BHolder<T>&)">BHolder</a>(const BHolder<T/>& other);</td></tr>
				<tr><td align="right">inline </td><td><a href="#~BHolder()">~BHolder</a>();</td></tr>
				<tr><td align="right">inline bool </td><td><a href="#empty() const">empty</a>() const;</td></tr>
				<tr><td align="right">inline bool </td><td><a href="#valid() const">valid</a>() const;</td></tr>
				<tr><td align="right">inline T* </td><td><a href="#ptr() const">ptr</a>() const;</td></tr>
				<tr><td align="right">inline T&amp; </td><td><a href="#ref() const">ref</a>() const;</td></tr>
				<tr><td align="right">inline UT* </td><td><a href="#as() const">as</a>() const;</td></tr>
				<tr><td align="right">inline </td><td><a href="#operator T* () const">operator T* </a>() const;</td></tr>
				<tr><td align="right">inline T&amp; </td><td><a href="#operator*() const">operator*</a>() const;</td></tr>
				<tr><td align="right">inline T* </td><td><a href="#operator->() const">operator-&gt;</a>() const;</td></tr>
				<tr><td align="right">inline const BHolder&amp; </td><td><a href="#operator = (T*)">operator = </a>(T* thing);</td></tr>
				<tr><td align="right">inline const BHolder&amp; </td><td><a href="#operator = (const BHolder&)">operator = </a>(const BHolder& other);</td></tr>
			</table>
			<div id="desc">
				<h2>详细介绍：</h2>
				<p>BHolder是东西（BThing）的引用计数器。需要注意的是其内容只能是东西。</p><p>一个东西被放入BHolder时其计数增加一，取出东西或计数器析构时东西的引用计数减一，如果其计数值为0则东西会被删除（delete）。</p>
			</div>
			<h2 id="docs">成员文档：</h2>
			<div id="BHolder()">
				<h3>inline BHolder();</h3>
				<p>构造一个空的计数器。</p>
			</div>
			<div id="BHolder(T*)">
				<h3>inline BHolder(T* thing);</h3>
				<p>构造一个计数器，传入一个东西。</p>
			</div>
			<div id="BHolder(const BHolder<T>&)">
				<h3>inline BHolder(const BHolder&lt;T&gt;&amp; other);</h3>
				<p>构造一个计数器，从别的占用器那里获得东西。</p>
			</div>
			<div id="~BHolder()">
				<h3>inline ~BHolder();</h3>
				<p>析构一个计数器，如果内部有东西，则对东西的引用计数值减一，若东西的计数值为0则删除这个东西。</p>
			</div>
			<div id="empty() const">
				<h3>inline bool empty() const;</h3>
				<p>判断此占用器是否为空。</p>
			</div>
			<div id="valid() const">
				<h3>inline bool valid() const;</h3>
				<p>判断此占用器是否有东西。</p>
			</div>
			<div id="ptr() const">
				<h3>inline T* ptr() const;</h3>
				<p>获取东西的指针。</p>
			</div>
			<div id="ref() const">
				<h3>inline T&amp; ref() const;</h3>
				<p>获取东西的引用。</p>
			</div>
			<div id="as() const">
				<h3>inline UT* as() const;</h3>
				<p>动态转换东西的类型为指定的类型。</p>
			</div>
			<div id="operator T* () const">
				<h3>inline operator T* () const;</h3><p>隐式转换类型为指定类型，这是最常用的方法。使用占用器的使用与指针形式一致。</p>
			</div>
			<div id="operator*() const">
				<h3>inline T&amp; operator*() const;</h3><p>使用与指针相同的星号取引用。</p>
			</div>
			<div id="operator->() const">
				<h3>inline T* operator-&gt;() const;</h3><p>将此占用器当作指针直接使用。</p>
			</div>
			<div id="operator = (T*)">
				<h3>inline const BHolder&amp; operator = (T* thing);</h3>
				<p>把引用器当作指针类型，直接使用=操作赋值，右操作数为东西。</p>
			</div>
			<div id="operator = (const BHolder&)">
				<h3>inline const BHolder&amp; operator = (const BHolder&amp; other);</h3>
				<p>把引用器当作指针类型，直接使用=操作赋值，右操作数为别的引用器。</p>
			</div>
		</div>
	</body>
</html>